package org.example.viteVantDemo.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.example.viteVantDemo.entity.TParam;
import org.example.viteVantDemo.entity.UserInfo;

import java.util.List;

@Mapper
public interface UserMapper extends BaseMapper<UserInfo> {
    @Select("select `value` from t_param where code = #{code} ")
    String queryParam(@Param("code") String code);

    @Update("update t_param set `value` = #{value } where code = 'version'")
    void updateVersion(@Param("value") int i);

    @Select("select * from t_param where group_type = #{assetsCode} ")
    List<TParam> queryAssetsType(@Param("assetsCode") String assetsCode);
}